# Contributor: Rasmus Thomsen <oss@cogitri.dev>
# Maintainer: Rasmus Thomsen <oss@cogitri.dev>
pkgname=gnome-firmware-updater
pkgver=3.34.0
pkgrel=2
pkgdesc="Install firmware on devices"
url="https://gitlab.gnome.org/hughsie/gnome-firmware-updater"
arch="x86_64 x86" # limited by fwupd
license="GPL-2.0-only"
makedepends="meson gtk+3.0-dev fwupd-dev libsoup-dev elogind-dev libxmlb-dev"
options="!check" # no tests
subpackages="$pkgname-lang"
source="https://gitlab.gnome.org/hughsie/gnome-firmware-updater/-/archive/$pkgver/gnome-firmware-updater-$pkgver.tar.gz"

build() {
	# man pages fail to build
	meson \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--localstatedir=/var \
		--buildtype=plain \
		-Dsystemd=false \
		-Delogind=true \
		-Dman=false \
		. output
	ninja -C output
}

package() {
	DESTDIR="$pkgdir" ninja -C output install
}

sha512sums="af4c82ca2ce9f3a36f614918cd6c97ae2b9dbab915d540760f4131938fd81038f315c1d664c3ade96da9164f96933eb9bf2c145f12f99e25753d3b29a7f0e2d1  gnome-firmware-updater-3.34.0.tar.gz"
